<template>
  <div>
    企业介绍
    <van-button type="primary" size="small">主要按钮</van-button>
    <van-button type="info" size="small">信息按钮</van-button>
    <van-button type="default" size="small">默认按钮</van-button>
    <van-button type="warning" size="small">警告按钮</van-button>
    <van-button type="danger" size="small">危险按钮</van-button>
    <component :is="componentName"></component>
    <nuxt-link to="/show.html?templateName=tplA">模板一</nuxt-link>
    <nuxt-link to="/show.html?templateName=tplB">模板二</nuxt-link>
  </div>
</template>
<script>
import tplA from '~/components/show/tplA.vue'
import tplB from '~/components/show/tplB.vue'
export default {
  name: 'ShowIndex',
  components: {
    tplA,
    tplB
  },
  data() {
    return {
      componentName: 'tplA'
    }
  },
  created() {
    this.componentName = this.$route.query.templateName || 'tplA'
  }
}
</script>
<style lang="less" scoped src="~/assets/less/index.less"></style>
